gen = UniformLinkRateGenerator(2);

adapter = WirelessAdapter(gen);

pack1 = Packet();
pack1.size_in_bytes = 10254;
pack1.id = 12344;

pack2 = Packet();
pack2.size_in_bytes = 454;
pack2.id = 8842;

pack3 = Packet();
pack3.size_in_bytes = 100000000;
pack3.id = 1552;

adapter.transmit_packet(pack1,1);
adapter.transmit_packet(pack2,2);
adapter.transmit_packet(pack3,1);

for k=1:10
    adapter.transmit_data(1000);
    packets = adapter.get_fully_transmitted_packets();
    if length(packets)~=0
        for i=1:length(packets)
            str = sprintf('packet %d completed transmission', packets(i).id);
            disp(str);
        end
    end
end

